package ar.edu.itba.it.paw.web.converter;

import java.util.Locale;

import org.apache.wicket.util.convert.IConverter;

import org.springframework.stereotype.Component;

import ar.edu.itba.it.paw.domain.Product;


@Component
public class ProductConverter implements IConverter {


	@Override
	public Object convertToObject(String arg0, Locale arg1) {
		throw new RuntimeException("Operation not supported");
	}

	@Override
	public String convertToString(Object source, Locale arg1) {
		return ((Product)source).getName();
	}
	
}
